package io.read;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

/**
 * @Package javaSE.io.read
 * @Author shimmer
 * @Date 2020/5/27 22:02
 * @TODO 从控制台读取字符串
 */
public class BRReadLine {
    public static void main(String[] args) throws IOException {
        readLine();
        System.out.println();
    }
    public static void readLine() throws IOException {
        BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
        String s;
        System.out.println("输入字符串，回车确定");
        System.out.println("输入end结束");
        do{
            s = bf.readLine();
            System.out.println(s);
        }while (!"end".equals(s));
    }
}
